package com.kvest.service_test;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import com.kvest.service_test.service.TestService;

public class ServiceTestActivity extends Activity {
    private static final String COMMAND_ID = "command_id";
    private static final String COMMAND_PARAM = "command_param";
    /**
     * Called when the activity is first created.
     */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
    }

    public void onTestServiceClick(View view) {
        for (int i = 0; i < 5; ++i) {
            Intent intent = new Intent(this, TestService.class);
            intent.putExtra(COMMAND_ID, i % 3);
            intent.putExtra(COMMAND_PARAM, "param " + i);
            startService(intent);
        }
    }
}
